<include file="Public:header"/>
<script type="text/javascript" src="__PUBLIC__/layer/laydate/laydate.js"></script>
<div id="main-content">
	<div id="top-alert" class="fixed alert alert-error" style="display: none;">
		<button class="close fixed" style="margin-top: 4px;">&times;</button>
		<div class="alert-content">警告内容</div>
	</div>
	<div id="main" class="main">
		<div class="main-title-h">
			<span class="h1-title"><a href="{:U('User/index')}">用户管理</a> &gt;&gt;</span>
			<span class="h1-title"><empty name="data">添加用户<else/>编辑用户</empty></span>
		</div>
		<div class="tab-wrap">
			<div class="tab-content">
				<form id="form" action="{:U('User/edit')}" method="post" class="form-horizontal">
					<div id="tab" class="tab-pane in tab">
						<div class="form-item cf">
							<table>
								<!-- <tr class="controls">
									<td class="item-label">国家区域 :</td>
									<td>
										<select id="area" name="area_id" class="form-control input-10x" placeholder="{:L('select_area')}">
											<option value="0">选择国家区域</option>

											<volist name="areas" id="vo">

												<option value="{$vo['id']}"  <eq name="data.area_id" value="$vo['id']">selected</eq> >
													{$vo['name_zh']} ({$vo['name_en']})
												</option>
											</volist>


										</select>
									</td>
									<td class="item-note"></td>
								</tr> -->
								<tr class="controls">
									<td class="item-label">用户名 :</td>
									<td>
										<input type="text" class="form-control input-10x" name="username" value="{$data.username}">
									</td>
									<td class="item-note"></td>
								</tr>
								<tr class="controls">
									<td class="item-label">英文昵称 :</td>
									<td>
										<input type="text" class="form-control input-10x" name="enname" value="{$data.enname}">
									</td>
									<td class="item-note"></td>
								</tr>
								<tr class="controls">
									<td class="item-label">用户密码 :</td>
									<td><input type="text" class="form-control input-10x" name="password" value=""></td>
									<td class="item-note">留空不更新</td>
								</tr>
								<tr class="controls">
									<td class="item-label">交易密码 :</td>
									<td><input type="text" class="form-control input-10x" name="paypassword" value="">
									</td>
									<td class="item-note">留空不更新</td>
								</tr>
								<tr class="controls">
									<td class="item-label">手机 :</td>
									<td>
										<input type="text" class="form-control input-10x" name="mobile" value="{$data.mobile}">
									</td>
									<td class="item-note"></td>
								</tr>
								<tr class="controls">
									<td class="item-label">手机认证时间 :</td>
									<td>
										<input type="text" class="form-control input-10x" name="mobiletime" value="{$data['mobiletime']|addtime}" onclick="laydate({istime: true, format: 'YYYY-MM-DD hh:mm:ss'})">
									</td>
									<td class="item-note"></td>
								</tr>
								<tr class="controls" >
									<td class="item-label">一代ID:</td>
									<td>
										<input type="text" class="form-control input-10x" name="invit_1" value="{$data.invit_1}">
									</td>
									<td class="item-note"></td>
								</tr>
								<tr class="controls" >
									<td class="item-label">二代ID :</td>
									<td>
										<input type="text" class="form-control input-10x" name="invit_2" value="{$data.invit_2}">
									</td>
									<td class="item-note"></td>
								</tr>
								<tr class="controls" >
									<td class="item-label">三代ID :</td>
									<td>
										<input type="text" class="form-control input-10x" name="invit_3" value="{$data.invit_3}">
									</td>
									<td class="item-note"></td>
								</tr>
<!--								<tr class="controls">
									<td class="item-label">密保问题 :</td>
									<td>
										<select id="mibao_question" name="mibao_question" class="form-control input-10x" style="">
		                                <option value="">请选择密保问题</option>
		                                <option value="你父亲的姓名"
		                                	<eq name="data.mibao_question" value="你父亲的姓名">selected</eq>
		                                >你父亲的姓名</option>
		                                <option value="你母亲的姓名"
											<eq name="data.mibao_question" value="你母亲的姓名">selected</eq>
		                                >你母亲的姓名</option>
		                                <option value="你爱人的姓名"
											<eq name="data.mibao_question" value="你爱人的姓名">selected</eq>
		                                >你爱人的姓名</option>
		                                <option value="你的出生日期"
		                                	<eq name="data.mibao_question" value="你的出生日期">selected</eq>

		                                >你的出生日期</option>
		                                <option value="你父亲的出生日期"
											<eq name="data.mibao_question" value="你父亲的出生日期">selected</eq>
		                                >你父亲的出生日期</option>
		                                <option value="你母亲的出生日期"
		                                	<eq name="data.mibao_question" value="你母亲的出生日期">selected</eq>

		                                >你母亲的出生日期</option>
		                                <option value="你爱人的出生日期"
											<eq name="data.mibao_question" value="你爱人的出生日期">selected</eq>
		                                >你爱人的出生日期</option>
		                            </select>
									</td>
									<td class="item-note">不选不更新</td>
								</tr>
								<tr class="controls">
									<td class="item-label">密保问题答案 :</td>
									<td>
										<input type="text" class="form-control input-10x" name="mibao_answer" value="{$data.mibao_answer}">
									</td>
									<td class="item-note">留空不更新</td>
								</tr>-->

								<tr class="controls">
									<td class="item-label">推广 :</td>
									<td><select name="is_generalize" class="form-control input-10x">
										<option value="1"
										<eq name="data.is_generalize" value="1">selected</eq>
										>一代</option>
										<option value="1"
										<eq name="data.is_generalize" value="3">selected</eq>
										>三代</option>
										<option value="0"
										<eq name="data.is_generalize" value="0">selected</eq>
										>禁用</option>
									</select></td>
									<td class="item-note"></td>
								</tr>
								<tr class="controls">
									<td class="item-label">手续费分组 :</td>
									<td>
										<select name="lv" class="form-control input-10x">
											<option value="0"
											<eq name="data.lv" value="0">selected</eq>
											>普通用户</option>
											<option value="1"
											<eq name="data.lv" value="1">selected</eq>
											>做市商</option>
										</select>
									</td>
									<td class="item-note">普通用户按照市场设置手续费收取,做市商手续费为0</td>
								</tr>
								
<!--								<tr class="controls">
									<td class="item-label">做市商后台 :</td>
									<td>
										<select name="backstage" class="form-control input-10x">
											<option value="0"
											<eq name="data.backstage" value="0">selected</eq>
											>不开放</option>
											<option value="1"
											<eq name="data.backstage" value="1">selected</eq>
											>开放C2C后台</option>
											<option value="2"
											<eq name="data.backstage" value="2">selected</eq>
											>开放超级后台</option>
										</select>
									</td>
									<td class="item-note">访问入口在前台个人中心</td>
								</tr>-->
								
								<tr class="controls">
									<td class="item-label">状态 :</td>
									<td><select name="status" class="form-control input-10x">
										<option value="1"
										<eq name="data.status" value="1">selected</eq>
										>正常</option>
										<option value="0"
										<eq name="data.status" value="0">selected</eq>
										>冻结</option>
									</select></td>
									<td class="item-note"></td>
								</tr>

								<tr class="controls">
									<td class="item-label"></td>
									<td>
										<div class="form-item cf">
											<button class="btn submit-btn ajax-post" id="submit" type="submit" target-form="form-horizontal">提交</button>
											<a class="btn btn-return" href="{$Think.server.HTTP_REFERER}">返 回</a>
											<notempty name="data.id"><input type="hidden" name="id" value="{$data.id}"/>
											</notempty>
										</div>
									</td>
								</tr>
							</table>
						</div>
					</div>
				</form>
			</div>
		</div>
	</div>
</div>
<script type="text/javascript">
	//提交表单
	$('#submit').click(function () {
		$('#form').submit();
	});
</script>
<include file="Public:footer"/>
<block name="script">
	<script type="text/javascript" charset="utf-8">
		//导航高亮
		highlight_subnav("{:U('User/index')}");
	</script>
</block>